import numpy as np


arr1 = np.array([2, 3, 1])
arr2 = np.array([3, 1, 2, 5])
print(arr2[arr1[:]])
